package com.hoshiicloud.user.mapper.store;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hoshiicloud.rbac.entity.SysUsers;
import com.hoshiicloud.rbac.vo.SysUsersVO;
import com.hoshiicloud.user.dto.userCenter.MemberDto;
import com.hoshiicloud.user.entity.store.StoreUsers;
import com.hoshiicloud.user.param.PlatStoreConsumerPageParam;
import com.hoshiicloud.user.param.rbac.SysUsersQueryParam;
import com.hoshiicloud.user.param.store.StoreDepartmentQueryParam;
import com.hoshiicloud.user.param.store.StoreUsersQueryParam;
import com.hoshiicloud.user.vo.store.StoreUsersVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 店铺部门 Mapper 接口
 * </p>
 *
 * @author campchen
 * @since 2019-07-24
 */
public interface StoreUsersMapper extends BaseMapper<StoreUsers> {
    /**
     * 分页查询店铺消费者列表
     * @param page
     * @param param
     * @return
     */
    Page<StoreUsersVO> storeUserPageList(IPage<StoreUsersVO> page, @Param("param") StoreUsersQueryParam param);


    /**
     * 店铺管理根据角色名称分页查询员工列表
     * @param page
     * @param param
     * @return
     */
    IPage<StoreUsersVO> getStoreUserByRoleName(IPage<StoreUsersVO> page, @Param("param") StoreUsersQueryParam param);

    /**
     * 批量删除或禁用数据 flag=1 删除,flag=2 禁用
     * @param idsArr
     * @param flag
     * @return
     */
    Boolean batchDeleteStoreUsers(@Param("idsArr")List<Long> idsArr, @Param("flag") int flag);

    List<Map> storeUserNameList(@Param("param") StoreUsersQueryParam param);

}
